import {lazy} from "react"
export const mainRouter =[
  {
    path: '/home/Articles',
    element:lazy(()=>import('../pages/home/Articles/Index'))
  },
  {
    path: '/home/Archives',
    element:lazy(()=>import('../pages/home/Archives/Index'))
  },
  {
    path: '/home/KnowledgeBooks',
    element:lazy(()=>import('../pages/home/KnowledgeBooks/Index'))
  },
  {
    path:"/home/Details/:id",
    element:lazy(()=>import('../pages/home/Detail/Index'))
  },
  {
    path:"/home/HomeRightTabDetail/:id",
    element:lazy(()=>import('../pages/home/Detail/HomeRightTabDetail'))
  }
]
const routes = [
  {
    path: '/home',
    element: lazy(()=>import('../pages/home/Index')),
    children: mainRouter
  },
  {
    path: '/serch',
    element: lazy(()=>import('../pages/home/Serch/Index')),
  },
  {
    path: '/login',
    element: lazy(()=>import('../pages/home/Login')),
  },
  {
    path:"/",
    to:'/home/Articles'
  },
]


export default routes
